package xyz.hubery.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import org.springframework.stereotype.Service;
import org.springframework.beans.factory.annotation.Autowired;

import java.util.Collections;
import java.util.List;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import xyz.hubery.dto.AdminBankDTO;
import xyz.hubery.mapper.AdminBankMapper;
import xyz.hubery.domain.AdminBank;
import xyz.hubery.mappers.AdminBankMappers;
import xyz.hubery.service.AdminBankService;
@Service
public class AdminBankServiceImpl extends ServiceImpl<AdminBankMapper, AdminBank> implements AdminBankService{


    @Override
    public List<AdminBankDTO> listAdminBanks() {
        List<AdminBank> adminBanks = list(new LambdaQueryWrapper<AdminBank>().eq(AdminBank::getStatus, 1));
        return AdminBankMappers.INSTANCE.toDTO(adminBanks);
    }
}
